<!DOCTYPE html>
<html>
<head>

    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">

    <!-- Page title -->
    <title>e护上门 | 店铺管理</title>

    <!-- Place favicon.ico and apple-touch-icon.png in the root directory -->
    <!--<link rel="shortcut icon" type="image/ico" href="favicon.ico" />-->

    <!-- Vendor styles -->
    <link rel="stylesheet" href="__PUBLIC__/vendor/fontawesome/css/font-awesome.css" />
    <link rel="stylesheet" href="__PUBLIC__/vendor/metisMenu/dist/metisMenu.css" />
    <link rel="stylesheet" href="__PUBLIC__/vendor/animate.css/animate.css" />
    <link rel="stylesheet" href="__PUBLIC__/vendor/bootstrap/dist/css/bootstrap.css" />
    <link rel="stylesheet" href="__PUBLIC__/vendor/sweetalert/lib/sweet-alert.css" />
	<link rel="stylesheet" href="__PUBLIC__/vendor/blueimp-gallery/css/blueimp-gallery.min.css" />
    <!-- App styles -->
    <link rel="stylesheet" href="__PUBLIC__/fonts/pe-icon-7-stroke/css/pe-icon-7-stroke.css" />
    <link rel="stylesheet" href="__PUBLIC__/fonts/pe-icon-7-stroke/css/helper.css" />
    <link rel="stylesheet" href="__PUBLIC__/styles/style.css">
	<style type="text/css">
		.pic{
			margin: 30px 0;
		}
		.pic a img{
			width: 240px;
			height: 160px;
			margin: 10px 0;
		}
		label{
			font-size: 18px !important;
			margin: 20px 0 10px 0;
		}
		.choose{
			text-align: center;
			margin-top: 50px;
		}
		.choose button{			
			font-size: 18px;
			width: 150px;
		}
        .message{
            color: #d49c16;
            font-size: 15px;
            font-weight: normal;
        }
        .status{
            color: red;
        }
        .bigname{
            color: #22312c;
        }
        form{
            display: inline;
        }
	</style>
</head>
<body>

<!--&lt;!&ndash; Simple splash screen&ndash;&gt;-->
<!--<div class="splash"> -->
	<!--<div class="color-line">-->
		<!---->
	<!--</div>-->
	<!--<div class="splash-title">-->
		<!--<h1>e护上门服务者后台</h1>-->
		<!--<p>e护上门-您的家庭医生，离你最近的医馆</p>-->
		<!--<img src="__PUBLIC__/images/loading-bars.svg" width="64" height="64" /> -->
	<!--</div> -->
<!--</div>-->
<!--[if lt IE 7]>
<!--<p class="alert alert-danger">You are using an <strong>outdated</strong> browser. Please <a href="http://browsehappy.com/">upgrade your browser</a> to improve your experience.</p>-->
<![endif]-->

<!-- Main Wrapper -->
<div id="wrapper">

    <div class="content animate-panel content-boxed">
        <div class="row">
            <div class="col-lg-12">
                <div class="hpanel blog-article-box">
                    <div class="panel-body lightBoxGallery">
                        <h2 class="bigname">
                            订单信息：
                        </h2>
                        <!--<button onclick="sendPerson()" style="color: black">派遣护理师</button>-->
                        <br>
                        <label>
                        	订单号：<span class="message">{$order_info.ordid}</span>
                        </label>
                        <label>
                            订单状态：<span class="message status">{$order_info.ordstatus}</span>
                        </label>
                        <br/>
                        <label>
                            下单时间：<span class="message">{:date('Y-m-d H:i:s',$order_info['starttime'])}</span>
                        </label>
                        <label>
                            服务时间：<span class="message">{:date('Y-m-d H:i:s',$order_info['servertime'])}</span>
                        </label>
                        <br/>
                        <label>
                            联系人姓名：<span class="message" id="ms-linkname">{$order_info.linkman}</span>
                            <input type="text" id="linkname" style="width: 120px">
                            <button type="button" onclick="updateOrder('name')">修改</button>
                        </label>
                        <br>
                        <label>
                            联系人电话：<span class="message" id="ms-linkphone">{$order_info.linkphone}</span>
                            <input type="text" id="linkphone" style="width: 120px">
                            <button type="button" onclick="updateOrder('phone')">修改</button>
                        </label>
                        <br/>
                        <label>
                            服务天数（次数）：<span class="message">{$order_info.amount} (天、次)</span>
                        </label>
                        <label>
                            总价格（￥）：<span class="message status" id="ms-price">{$order_info['price'] * $order_info['amount']} 元</span>
                            <!--<input type="text" id="price" style="width: 120px">-->
                            <!--<button type="button" onclick="updateOrder('price')">修改</button>-->
                        </label>
                        <br>
                        <label>
                            备注信息：<span class="message status" id="ms-instruction">{$order_info['instruction']}</span>
                        </label>
                        <br/>
                        <br/>


                        <!--<h2 class="bigname">-->
                            <!--套餐信息：-->
                        <!--</h2>-->
                        <!--<br>-->
                        <!--<label>-->
                            <!--服务类型：<span class="message">{$order_info.server_type}</span>-->
                        <!--</label>-->
                        <!--<br/>-->
                        <!--<label>-->
                            <!--套餐类型：<span class="message status">{$package.name}{$package.price}{$package.unit}</span>-->
                        <!--</label>-->
                        <!--<br/>-->
                        <!--<br/>-->

                        <h2 class="bigname">
                            被服务人信息：
                        </h2>
                        <label>
                            姓名：<span class="message">{$server_people.name}</span>
                        </label>
                        <br>
                        <label>
                            年龄：<span class="message">{$server_people.age}</span>
                        </label>
                        <label>
                            性别：<span class="message">{$server_people.sex}</span>
                        </label>
                        <br>
                        <label>
                            身高：<span class="message">{$server_people.height}cm</span>
                        </label>
                        <label>
                            体重：<span class="message">{$server_people.weight}斤</span>
                        </label>
                        <br>
                        <label>
                            城市：<span class="message">{$server_people.city}</span>
                        </label>
                        <label>
                            详细地址：<span class="message">{$server_people.detail_adress}</span>
                        </label>
                        <br>
                        <label>
                            是否自理：<span class="message status">{$server_people.self_live}</span>
                        </label>
                        <br>
                    </div>
                    <div class="panel-footer">
		                <span class="pull-right">
		                    <i class="fa fa-hospital-o"> </i>e护上门
		                </span>
                        <i class="fa fa-user"> </i>订单管理
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>

<!-- The Gallery as lightbox dialog, should be a child element of the document body -->
<div id="blueimp-gallery" class="blueimp-gallery">
    <div class="slides"></div>
    <h3 class="title"></h3>
    <a class="prev">‹</a>
    <a class="next">›</a>
    <a class="close">×</a>
    <a class="play-pause"></a>
    <ol class="indicator"></ol>
</div>

<!-- Vendor scripts -->
<script src="__PUBLIC__/scripts/jquery-1.11.2.js"></script>
<script type="text/javascript" src="__PUBLIC__/ext/layer/layer.js"></script>


<script>
    function updateOrder(item) {
        if(item == 'name'){
            var name = $('#linkname').parent().find('input').val();
            var id = "{$order_info['id']}";
            $.getJSON("{:U('ajaxUpdateOrder')}",{name:name,id:id},function (res) {
                if(res.status == '1'){
                    $('#ms-linkname').text(res.name);
                    layer.msg('修改成功', {icon: 6});
                }else {
                    layer.msg('修改失败', {icon: 5});
                }
            });
        }else if(item == 'phone'){
            var phone = $('#linkphone').parent().find('input').val();
            var id = "{$order_info['id']}";
            $.getJSON("{:U('ajaxUpdateOrder')}",{phone:phone,id:id},function (res) {
                if(res.status == '1'){
                    $('#ms-linkphone').text(res.phone);
                    layer.msg('修改成功', {icon: 6});
                }else {
                    layer.msg('修改失败', {icon: 5});
                }
            });
        }
//        else if(item == 'price'){
//            var price = $('#price').parent().find('input').val();
//            var id = "{$order_info['id']}";
//            $.getJSON("{:U('ajaxUpdateOrder')}",{price:price,id:id},function (res) {
//                if(res.status == '1'){
//                    $('#ms-price').text(res.price);
//                    layer.msg('修改成功', {icon: 6});
//                }else {
//                    layer.msg('修改失败', {icon: 5});
//                }
//            });
//        }
    }
    
    function sendPerson() {
        
    }

</script>

</body>
</html>